<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title>事件绑定</title>
		
	</head>
	<body>
		<img id="light" src="img/pic_bulboff.gif" onclick="fun()" />
		<img id="light1" src="img/pic_bulboff.gif" />
		<h1 id="title">悔创阿里杰克马</h1>
		
		<script>
			function fun(){
				alert("我被点了");
				alert("我又被点了");
			}
			
			 function  fun1() {
				alert("老店我");
			}
			//获取light1对象
			var light1 = document.getElementById("light1");
			//绑定事件
			light1.onclick = fun1;
		</script>
	</body>
</html>
